package com.yint.http;

import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;
import java.util.concurrent.Future;

/**
 * 线程池
 * 
 * @author 殷田
 *
 */
public class ThreadPool
{

	private ExecutorService cachePool = Executors.newCachedThreadPool();

	public ThreadPool()
	{

	}

	public Future< ? > addCacheTask( Runnable task )
	{
		if ( task == null )
		{
			return null;
		}
		return cachePool.submit( task );
	}

}